package com.qunar.qcf.handler.transport;

import com.qunar.qcf.core.session.IoSession;


/**
 * server消息发送者
 * 
 * @author zhangwan
 * @email wan.zhang@qunar.com
 * 
 */
public class ServerSender {
	private final IoSession session;
	private final Transport transport;

	public ServerSender(IoSession session, Transport transport) {
		this.session = session;
		this.transport = transport;
	}

	public void send(Object message) {
		transport.setMessage(message);
		session.write(transport);
	}
	
}
